/*
 * @Date: 2021-12-07 16:49:47
 * @LastEditors: 春贰
 * @Desc: 
 * @LastEditTime: 2022-03-16 14:39:09
 * @FilePath: \web\src\api\module\permission.js
 */
import http from '../http'

const Api = {
    tree: '/permission/tree',
    add: '/permission/add',
    edit: '/permission/edit', 
    remove: '/permission/remove', 
}

export const tree = (data) => {  
    console.log(data,data);
    return http.request({
        url: Api.tree,
        data: data,
        method: 'POST'
    })
}

export const assign = data => {
    return http.request({
        url: Api.assign,
        data: data,
        method: 'GET'
    })
}

export const add = data => {
    return http.request({
        url: Api.add,
        data: data,
        method: 'POST'
    })
}

export const edit = data => { 
    return http.request({
        url: Api.edit,
        data: data,
        method: 'POST'
    })
}

export const remove = data => {
    return http.request({
        url: Api.remove,
        data: data,
        method: 'POST'
    })
}

 